import httpRequest from '../../utils/request'
import modules from '../modules'
const defaultRoute = 'Shopfloor_Workshopinfo'
const controllerName = 'Workshopinfo'

export interface WorkshopinfoParam {
  id: string;
  PageSize: string;
  PageIndex: string;
}


// 获取车间列表
export function ApiGetShopfloor_WorkshopinfoPageListAsync(param: WorkshopinfoParam) {
  return httpRequest({
    url: `${modules.shopfloorModuleUrl}/${controllerName}/Get${defaultRoute}PageList`,
    method: "Post",
    data: param,
  });
}

// 批量删除车间
export function ApiDeletionShopfloor_WorkshopinfoAsync(param: WorkshopinfoParam) {
  return httpRequest({
    url: `${modules.shopfloorModuleUrl}/${controllerName}/Deletion${defaultRoute}`,
    method: "Post",
    data: param,
  });
}


// 添加车间
export function ApiCreateShopfloor_WorkshopinfoAsync(param: WorkshopinfoParam) {
  return httpRequest({
    url: `${modules.shopfloorModuleUrl}/${controllerName}/Create${defaultRoute}`,
    method: "Post",
    data: param,
  });
}


// 更新车间
export function ApiUpdateShopfloor_WorkshopinfoAsync(param: WorkshopinfoParam) {
  return httpRequest({
    url: `${modules.shopfloorModuleUrl}/${controllerName}/Update${defaultRoute}`,
    method: "Post",
    data: param,
  });
}